package com.bookstore.back.entity;

import com.baomidou.mybatisplus.annotation.IdType;
import com.baomidou.mybatisplus.annotation.TableField;
import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.annotation.TableName;
import lombok.Data;
import lombok.EqualsAndHashCode;

import java.io.Serializable;

/**
 * 新闻分类关系实体类
 * 
 * @author 程序猿_Ti
 * @since 2025-07-23
 */
@Data
@EqualsAndHashCode(callSuper = false)
@TableName("news_category_relation")
public class NewsCategoryRelation implements Serializable {

    private static final long serialVersionUID = 1L;

    /**
     * 关联ID
     */
    @TableId(value = "id", type = IdType.AUTO)
    private Integer id;

    /**
     * 新闻ID
     */
    @TableField("news_id")
    private Integer newsId;

    /**
     * 分类ID
     */
    @TableField("category_id")
    private Integer categoryId;
}
